// @ts-ignore
import { request } from '@/request/request';
import { Login } from './type'

/**
 * 登录.
 * */
export const login = (data : Login.Params) : Promise<Login.Response> => {
	return request({ url: '/auth/login', data })
}

/**
 * 获取openid.
 * @param data
 */
export const getSession = (data: any): Promise<any> => {
	return request({ url: '/login/wechatMini/session', data })
}

/**
 * 解密手机号. 登录.
 * @param data
 */
export const loginByMobile = (data: any): Promise<any> => {
	return request({ url: '/login/wechatMini/miniMobile', data })
}


